import React from 'react';
import ReactDom from 'react-dom';
import Index from './index';
import ComponentList from './components/list';
import {Route, Router} from 'react-router'
import {createBrowserHistory, createHashHistory, createMemoryHistory} from 'history';

export default class Root extends React.Component{
    render() {
        return (
            <Router history={createBrowserHistory()}>
                <Route component={Index} path='/'></Route>
                <Route component={ComponentList} path='list'> </Route>
            </Router>
        );
    };
}

ReactDom.render(<Root/>, document.getElementById('example'));